$(function () {
    $('#banner-carousel').carousel({
        interval: 2000
    })
   $('#myTab li:eq(0) a').tab('show');
   
   var swiper = new Swiper('.teacher-swiper', {
       slidesPerView: 4,
       spaceBetween: 15,
       pagination: {
           el: '.swiper-pagination',
           clickable: true,
       },
       navigation: {
           nextEl: '.swiper-button-next',
           prevEl: '.swiper-button-prev',
       },
       loop: true,
   });
  
   $(".swiper-slide").mouseenter(function () {
       $(this).find('.mask').css('bottom', '0px')
   })
   $(".swiper-slide").mouseleave(function () {
       $(this).find('.mask').css('bottom', '-150px')
   })

   $(window).scroll(function () {
       var scrollTop = $(window).scrollTop();
       if(scrollTop >= 200){
           $(".dhjy-qq").css({
               'position': 'fixed',
               'top': '0px'
           })
       }else {
           $(".dhjy-qq").css({
               'position': 'absolute',
               'top': '10px'
           })
       }
   });
})
